import json
from conf.setting import CASE_DATA_PATH
import os



data_path = os.path.join(CASE_DATA_PATH, "body.json")


# 导入全局变量
def set_globals():
  with open(data_path, 'r') as f:
    config = json.load(f)
    global deviceid
    deviceid = config['speechSynthesisPlay']['requestData']['deviceId']


    # 调用设置全局变量的函数
    set_globals()

    # 之后可以在代码中使用MY_GLOBAL_VAR
    print(deviceid)




